﻿using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp4
{
    class Program
    {
        static void Main(string[] args)
        {
            List<Student> ls = new List<Student>();
            Hashtable ht = new Hashtable();

            Student s1 = new Student(1, "张三", 18);
            Student s2 = new Student(2, "老八", 17);
            Student s3 = new Student(3, "罗翔", 19);

            ht.Add(s1.Name, s1);
            ht.Add(s2.Name, s2);
            ht.Add(s3.Name, s3);
        }
        static void Text(Hashtable hashtable) 
        {
            Console.WriteLine("1、添加学生信息。2、查询学生信息，3、删除学生信息。");
            int num = int.Parse(Console.ReadLine());
            object list = null;
            switch (num) 
            {
                case 1:
                    add(hashtable, list);
                    break;
                case 2:
                    chaxun(hashtable, list);
                    break;
                case 3:
                    shanchu(hashtable, list);
                    break;
                default:
                    break;
            }
        }

        private static void shanchu(Hashtable hashtable, object list)
        {
            Console.WriteLine("请输入学号：");
            int a = int.Parse(Console.ReadLine());

            Console.WriteLine("请输入姓名：");
            string b = Console.ReadLine();

            Console.WriteLine("请输入年龄：");
            int c = int.Parse(Console.ReadLine());

        }

        private static void chaxun(Hashtable hashtable, object list)
        {
            Console.WriteLine("1、查询所有（按学号排序）2、查询所有（按姓名排序），2、查询所有（按年龄排序）4、按学号查询（查没有，则打印查无此学生）5、退出");
            int a = int.Parse(Console.ReadLine());
            throw new NotImplementedException();
        }

        private static void add(Hashtable hashtable, object list)
        {
            throw new NotImplementedException();
        }
    }
}
